<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <style type="text/css">
        .box{
            width: 400px;
            /*height: 300px;*/
            border: 1px solid black;
        }

        .box div{
            width: 100px;
            height: 100px;
            border: 1px solid black;
            /* 浮动
            使块元素可以横向显示， 从左往右 ， 从右往左
            */
            float: left;
        }

        .box p{
            /*清除浮动
             */
            clear: left;
        }

    </style>
</head>
<body>

<div class="box">
    <div>1</div>
    <div>2</div>
    <div>3</div>
    <p>test</p>
</div>

</body>
</html>